<!DOCTYPE html>
<html lang="zh-CN" xmlns:th="http://www.thymeleaf.org">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>门户系统 - 登录</title>
    <style>
        * {
            margin: 0;
            padding: 0;
            box-sizing: border-box;
        }
        
        body {
            font-family: 'Microsoft YaHei', 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
            background: linear-gradient(135deg, #0ea5e9 0%, #2563eb 100%);
            min-height: 100vh;
            display: flex;
            align-items: center;
            justify-content: center;
        }
        
        .login-container {
            background: white;
            border-radius: 20px;
            box-shadow: 0 20px 60px rgba(0,0,0,0.15);
            padding: 60px;
            max-width: 450px;
            width: 90%;
            text-align: center;
        }
        
        .logo {
            font-size: 3em;
            color: #0ea5e9;
            margin-bottom: 20px;
        }
        
        h2 {
            color: #333;
            margin-bottom: 10px;
            font-size: 2.2em;
        }
        
        .subtitle {
            color: #666;
            margin-bottom: 40px;
            font-size: 1.1em;
        }
        
        .login-btn {
            width: 100%;
            padding: 15px 20px;
            background: linear-gradient(135deg, #0ea5e9 0%, #2563eb 100%);
            color: white;
            border: none;
            border-radius: 10px;
            font-size: 1.1em;
            font-weight: bold;
            cursor: pointer;
            transition: all 0.3s ease;
            margin-bottom: 20px;
            text-decoration: none;
            display: inline-block;
        }
        
        .login-btn:hover {
            transform: translateY(-2px);
            box-shadow: 0 10px 30px rgba(14, 165, 233, 0.4);
            text-decoration: none;
            color: white;
        }
        
        .login-status {
            background-color: #fee2e2;
            color: #dc2626;
            padding: 10px;
            border-radius: 5px;
            margin-bottom: 20px;
            font-weight: bold;
            border: 1px solid #dc2626;
        }
        
        .system-status {
            display: flex;
            align-items: center;
            justify-content: center;
            margin-bottom: 20px;
            color: #10b981;
            font-size: 0.9em;
        }
        
        .status-dot {
            width: 8px;
            height: 8px;
            background: #10b981;
            border-radius: 50%;
            margin-right: 8px;
            animation: pulse 2s infinite;
        }
        
        @keyframes pulse {
            0% { opacity: 1; }
            50% { opacity: 0.5; }
            100% { opacity: 1; }
        }
        
        .info-section {
            background: #f0f9ff;
            padding: 25px;
            border-radius: 10px;
            margin-top: 30px;
            text-align: left;
        }
        
        .info-section h3 {
            color: #0ea5e9;
            margin-bottom: 15px;
            text-align: center;
        }
        
        .feature-list {
            list-style: none;
            padding: 0;
        }
        
        .feature-list li {
            padding: 8px 0;
            color: #555;
            position: relative;
            padding-left: 25px;
        }
        
        .feature-list li:before {
            content: "✓";
            position: absolute;
            left: 0;
            color: #0ea5e9;
            font-weight: bold;
        }
        
        .footer {
            margin-top: 30px;
            color: #999;
            font-size: 0.9em;
        }
    </style>
</head>
<body>
    <div class="login-container">
        <div class="logo">🏢</div>
        <h2>企业统一门户</h2>
        <p class="subtitle">一站式访问企业所有系统</p>
        
        <div class="system-status">
            <div class="status-dot"></div>
            <span>系统运行正常</span>
        </div>
        
        <!-- 未登录状态标记 -->
        <div class="login-status">
            <span style="font-size: 16px;">⚠️ 当前状态：未登录</span>
        </div>
        
        <!-- OAuth2 登录按钮 -->
        <a class="login-btn" th:href="@{/oauth2/authorization/custom-client}">
            🔐 统一账号登录
        </a>
        
        <!-- 系统功能介绍 -->
        <div class="info-section">
            <h3>🚀 门户功能</h3>
            <ul class="feature-list">
                <li>统一身份认证</li>
                <li>一次登录，畅通全系统</li>
                <li>OA系统快捷访问</li>
                <li>风控系统直接跳转</li>
                <li>安全令牌自动传递</li>
            </ul>
        </div>
        
        <div class="footer">
            <p>Spring Boot 3 + OAuth2 + JWT</p>
            <p>企业统一门户系统 v1.0</p>
        </div>
    </div>
</body>
</html>